<!DOCTYPE html>
<html>

	<head>
		<meta charset="utf-8">
		<meta name="viewport" content="initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
		<title>我愛你</title>
		<link href="css/mui.min.css" rel="stylesheet" />
		<script src="js/mui.min.js"></script>
		<script type="text/javascript">
			mui.init();
			map = null;
			mui.plusReady(function(){

				map = new plus.maps.Map("map");
				getUserLocation();
				map.setZoom(17);
				console.log(1111);
			});

			function getUserLocation() {
				map.getUserLocation(function(state, point){
					map.showUserLocation(true);
					map.setCenter(point);
					
				});
			}

//			// H5 plus事件处理
//			function plusReady() {
//				// 确保DOM解析完成
//				if(!em || !window.plus || map) { return };
//				map = new plus.maps.Map("map");
//				getUserLocation();
//				map.setZoom(17);
//			}
//			if(window.plus) {
//				plusReady();
//			} else {
//				document.addEventListener("plusready", plusReady, false);
//			}
			// DOMContentloaded事件处理
//			document.addEventListener("DOMContentLoaded", function() {
//				em = document.getElementById("map");
//
//			}, false);
			// 获取用户的当前位置信息
			
		</script>
		<style type="text/css">
			#map {
				width: 100%;
				position: absolute;
				z-index: -100;
				top: 100px;
				bottom: 0px;
				line-height: 200px;
				text-align: center;
				background: #FFFFFF;
			}
		</style>
	</head>

	<body>
		<!-- 侧滑导航根容器 -->
		<div class="mui-slide-in mui-off-canvas-wrap mui-draggable">
			<!-- 主页面容器 -->
			<div class="mui-inner-wrap">
				<!-- 菜单容器 -->
				<aside class="mui-off-canvas-left">
					<div class="mui-scroll-wrapper">
						<div class="mui-scroll">
							<!-- 菜单具体展示内容 -->
							......
						</div>
					</div>
				</aside>

				<!-- 主页面内容容器 -->
				<div class="mui-content mui-scroll-wrapper">
					<div class="mui-scroll" id="map">
						<!-- 主界面具体展示内容 -->
						
					</div>
				</div>
			</div>
		</div>
	</body>

</html>